package com.lanou.dllo.findfood.activity;

import android.app.Activity;
import android.content.ContentResolver;
import android.content.Intent;
import android.graphics.Bitmap;
import android.graphics.BitmapFactory;
import android.net.Uri;
import android.os.Bundle;
import android.widget.ImageView;
import android.widget.TextView;

import com.lanou.dllo.findfood.R;
import com.lanou.dllo.findfood.tools.StringUtil;
import com.lanou.dllo.findfood.tools.TimeUtil;

import java.io.FileNotFoundException;

/**
 * Created by dllo on 15/11/7.
 */
public class SharchedActivity extends Activity{

private ImageView NewfoodImage;
    private TextView sendfoodName,sendshare,sendtag,nowTime;
private Bitmap bitmap;
    private String name,share,tag;
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_sharched);
        initView();
        getImage();
    }
  private void   initView(){
      NewfoodImage = (ImageView) findViewById(R.id.sendfoodImage);
      sendfoodName = (TextView) findViewById(R.id.sendfoodName);
      sendshare = (TextView) findViewById(R.id.sendshare);
      sendtag = (TextView) findViewById(R.id.sendtag);
      nowTime = (TextView) findViewById(R.id.nowTime);



    }
    private  void   getImage(){
        Intent intent = getIntent();
        bitmap =intent.getParcelableExtra("sendImage");
        NewfoodImage.setImageBitmap(bitmap);
        sendfoodName.setText(intent.getStringExtra("dish_Name"));
        sendshare.setText(intent.getStringExtra("sendText"));
        sendtag.setText(intent.getStringExtra("tag"));
        nowTime.setText(intent.getStringExtra("time"));

    }
}
